package ferrovias.clases;

public abstract class TrenBelgranoNorte extends Tren {
	public static int minRetSal=6;
	public static int minSalOrt=5;
	public static int minOrtDlv=6;
	public static int minDlvPad=3;
	public static int minPadFlo=3;
	public static int minFloMun=3;
	public static int minMunCar=2;
	public static int minCarAde=3;
	public static int minAdeBou=4;
	public static int minBouMon=6;
	public static int minMonTor=3;
	public static int minTorSou=4;
	public static int minSouVdm=2;
	public static int minVdmPol=3;
	public static int minPolNog=3;
	public static int minNogGb=4;
	public static int minGbTa=3;
	public static int minTaTort=3;
	public static int minTortAlb=3;
	public static int minAlbDvs=4;
	public static int minDvsVro=7;
	
	public static int minVroDvs=8;
	public static int minDvsAlb=3;
	public static int minAlbTort=3;
	public static int minTortTa=3;
	public static int minTaGb=4;
	public static int minGbNog=3;
	public static int minNogPol=2;
	public static int minPolVdm=3;
	public static int minVdmSou=3;
	public static int minSouTor=4;
	public static int minTorMon=3;
	public static int minMonBou=7;
	public static int minBouAde=3;
	public static int minAdeCar=2;
	public static int minCarMun=3;
	public static int minMunFlo=3;
	public static int minFloPad=2;
	public static int minPadDlv=4;
	public static int minDlvOrt=5;
	public static int minOrtSal=6;
	public static int minSalRet=6;
	
	private int origen;
	private int destino;
	
	public int getOrigen(){
		return this.origen;
	}
	
	public int getDestino(){
		return this.destino;
	}
	
	public void setOrigen(int origen){
		this.origen=origen;
	}
	
	public void setDestino(int destino){
		this.destino=destino;
	}
	
	protected Hora[] horaEstaciones;
	private int numero;
	
	public TrenBelgranoNorte(int numero){
		horaEstaciones=new Hora[24];
		this.numero=numero;
	}
	
	public int getNumero(){
		return this.numero;
	}
	
	public Hora[] getHoraEstaciones(){
		return this.horaEstaciones;
	}
	
	public static TrenBelgranoNorte getTren(int estPart, int estLlegada,Hora hora,int numero){
		if(estPart==0){
			if(estLlegada==9)
				return new TrenRetiroBoulogne(hora, numero);
			if(estLlegada==14)
				return new TrenRetiroPolvorines(hora, numero);
			if(estLlegada==16)
				return new TrenRetiroGrandbourg(hora, numero);
			if(estLlegada==20)
				return new TrenRetiroDelviso(hora, numero);
			if(estLlegada==21)
				return new TrenRetiroVillarosa(hora, numero);			
		}
		if(estPart==9){
			if(estLlegada==0)
				return new TrenBoulogneRetiro(hora, numero);
			if(estLlegada==21)
				return new TrenBoulogneVillaRosa(hora, numero);
		}
		if(estPart==14){
			if(estLlegada==0)
				return new TrenPolvorinesRetiro(hora, numero);			
		}
		if(estPart==16){
			if(estLlegada==0)
				return new TrenGrandbourgRetiro(hora, numero);
		}
		if(estPart==20){
			if(estLlegada==0)
				return new TrenDelvisoRetiro(hora, numero);
		}
		if(estPart==21){
			if(estLlegada==9)
				return new TrenVillarosaBoulogne(hora, numero);
			if(estLlegada==0)
				return new TrenVillarosaRetiro(hora, numero);			
		}
		
		return null;
	}

	public abstract boolean circulaALaHora(Hora hora);
	
	public abstract int estacionPartida();
	
	public abstract int estacionLLegada();
	

}
